This function verifies that a string is a valid time, in the form hh:mm:ss am/pm, where seconds are optional. It accepts military time (hour between 0 and 23) as long as am/pm isn't specified. It requires am/pm when the hour is less than or equal to 12. |
JavaScript Source Code 2002: Forms: Time Validation
Simply click inside the window below, use your cursor to highlight the script, and copy (type Control-c or Apple-c) the script into a new file in your text editor (such as Note Pad or Simple Text) and save (Control-s or Apple-s). The script is yours!!!
|